package com.yonyou.cyxdms.sysAuth.service.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.yonyou.cyx.framework.bean.dto.base.BaseDTO;
import com.yonyou.cyx.function.utils.bean.BeanMapperUtil;
import com.yonyou.cyxdms.framework.bean.entity.base.DMSBasePO;

import java.io.Serializable;

/**
 * <p>
 * app版本表
 * </p>
 *
 * @author quankk
 * @since 2019-03-05
 */
@TableName("tm_app_version")
public class AppVersionPO extends DMSBasePO<AppVersionPO> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "VERSION_ID", type = IdType.AUTO)
    private String versionId;
    /**
     * 版本
     */
    @TableField("VERSION_NO")
    private String versionNo;

    @TableField("APP_TYPE")
    private String appType;

    @TableField("REMARK")
    private String remark;

    @TableField("URL")
    private String url;

    @TableField("FILE_NAME")
    private String fileName;

    @TableField("App_Id")
    private String appId;

    @TableField("status")
    private Integer status;

    @TableField("is_Forced")
    private Integer isForced;

    public String getVersionId() {
        return versionId;
    }

    public void setVersionId(String versionId) {
        this.versionId = versionId;
    }

    public String getFileName() {
        return fileName;
    }

    public void setFileName(String fileName) {
        this.fileName = fileName;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Integer getIsForced() {
        return isForced;
    }

    public void setIsForced(Integer isForced) {
        this.isForced = isForced;
    }

    public String getAppId() {
        return appId;
    }

    public void setAppId(String appId) {
        this.appId = appId;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public AppVersionPO() {
        super();
    }

    public String getAppType() {
        return appType;
    }

    public void setAppType(String appType) {
        this.appType = appType;
    }

    public String getVersionNo() {
        return versionNo;
    }

    public void setVersionNo(String versionNo) {
        this.versionNo = versionNo;
    }

    @Override
    protected Serializable pkVal() {
        return null;
    }

    @Override
    public String toString() {
        return "AppVersionPO{" +
                "versionId='" + versionId + '\'' +
                ", versionNo='" + versionNo + '\'' +
                ", appType='" + appType + '\'' +
                ", remark='" + remark + '\'' +
                ", url='" + url + '\'' +
                ", fileName='" + fileName + '\'' +
                ", appId='" + appId + '\'' +
                ", status=" + status +
                ", isForced=" + isForced +
                '}';
    }

    /**
     * 将PO 信息转化为DTO
     *
     * @param dto 需要进行转换的dto
     * @author quankk
     * @since 2018/7/22 0022
     */
    protected <T extends BaseDTO> void transDtoToPo(T dto) {
        BeanMapperUtil.copyProperties(this, dto, "${keyPropertyName}");
    }


}
